﻿[[title="用户信息",pagesize="20",orderby="",condition=""]]
<script language="javascript" type="text/javascript">
    function userSave() {
        var opt = wmsCommon.getQueryValue("opt")
        if (opt == "1") {
            var password = document.getElementById("userInfo$password$0").value;
            if (password != undefined && password != null && password != "") {
                var rtn = wmsCommon.execCommand("sys(#UserManager.GetEnCodePassWord('" + escape(password) + "'))");
                if (rtn != "") {
                    document.getElementById("userInfo$password$0").value = rtn;
                }
            }
        }
        wmsCommon.saveMethod(null,true);
        //wmsCommon.pubSaveAndRefPage(null, true);
    }
</script>
<table class="DisplayArea" cellpadding="0" cellspacing="0" align="center" style="width:100%;height:100%">
    <tr>
        <td class="headmiddle" style="height: 26px">
            #if($request.QueryString.get_Item("opt")=="1") 
                    <span id="LableTitle">新增用户信息</span>
            #else
                   <span id="LableTitle2">修改用户信息</span>
            #end
        </td>
    </tr>    <tr>
        <td style="padding:10; vertical-align:text-top;">
            <!--edit content start-->
            <table class="singleEdit" cellpadding="0" cellspacing="0">
                <tr>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("userNo").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("userNo").Render("FocusedTextBox,checkExists=notin;")
                    </td>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("userName").DisplayName 
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("userName").Render("FocusedTextBox,checkExists=notin;")
                    </td>
                </tr>
                <tr>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("displayName").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("displayName").Render()
                    </td>
                    <td class="tblEditPrompt">
                      #if($request.QueryString.get_Item("opt")=="1") 
                        $userInfo.Columns.get_Item("password").DisplayName                  
                      #end
                    </td>
     
                      #if($request.QueryString.get_Item("opt")=="1") 
                                     <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("password").Render()     
                           </td>
                        #else
                        <td class='tblEditText' style="display:none;">     
                         $userInfo.Rows.get_Item(0).get_Item("password").Render()        
                        </td>
                      #end
                   
                </tr>
                <tr>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("departWBS").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("departWBS").Render()
                    </td>

                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("email").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("email").Render()
                    </td>
                </tr>
                     <tr>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("phoneNum").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("phoneNum").Render()
                    </td>

                        <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("MobilePhone").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("MobilePhone").Render()
                    </td>               
                </tr>               
   
                     <tr>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("isAdmin").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("isAdmin").Render()
                    </td>

                        <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("isDisabled").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("isDisabled").Render()
                    </td>               
                </tr>
                <tr>
                          <td class='tblEditPrompt'>$userInfo.Columns.get_Item("remark").DisplayName()</td>
                    <td class='tblEditText' colspan="3" style="height: 60px">
                        $userInfo.Rows.get_Item(0).get_Item("remark").Render()
                    </td>
                </tr>

                <tr style="display:none;">
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("creatorNo").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("creatorNo").Render()
                    </td>
                    <td class="tblEditPrompt">
                        $userInfo.Columns.get_Item("createTime").DisplayName
                    </td>
                    <td class='tblEditText'>
                        $userInfo.Rows.get_Item(0).get_Item("createTime").Render("defaultValue=$dataContext.GetDate();")
                    </td>
                </tr>
            </table>
            <!-- edit content end-->
        </td>
    </tr>
    <tr style="height: 20px;">
        <td colspan="4" valign="middle" style="text-align: center; height: 20px;">
            <div style="height: 20px; background-color: rgb(233, 231, 215);">
                        $render.RenderButton(" text=保存; displayType=button ; actionType=save; clientMethod=submitValidatePage();serverMethod=userSave();")
                        $render.RenderButton(" text=关闭; displayType=button ; actionType=close; clientMethod=wmsCommon.closeWin();")
            </div>
        </td>
    </tr>
</table>

